home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Network Support Library
/
RoseWare - Network Support Library.iso
/
btrieve
/
xtr401.exe
/
PATCHXQL.BAT
< prev
next >
Wrap
DOS Batch File
|
1991-06-20
|
3KB
|
133 lines
echo off
CLS
echo *** MAKE SURE THAT YOU USE THE ORIGINAL (UNPATCHED) RELEASED VERSION
echo OF THE PRODUCT YOU ARE PATCHING. PATCHING AN ALREADY PATCHED COPY
echo MAY CAUSE UNPREDICTABLE ERRORS.
echo
echo
::
IF %1! == ! GOTO PARAM
IF %1 == XQLP GOTO START
IF %1 == XQLPO GOTO START
IF %1 == XQLPOS2 GOTO OS2
IF %1 == xqlp GOTO START
IF %1 == xqlpo GOTO START
IF %1 == xqlpos2 GOTO OS2
GOTO PARAM
::
:START
::
SET X201ORG=%1.ORG
SET X201FIL=%1.EXE
SET X201PAT=%1PAT.201
SET X201TYP=DOS
IF %1 == XQLU GOTO UTIL
IF %1 == xqlu GOTO UTIL
GOTO PATCH
::
:OS2
::
SET X201ORG=XQLP.OS2
SET X201FIL=XQLP.DLL
SET X201PAT=%1.201
SET X201TYP=OS2
GOTO PATCH
::
:PATCH
IF NOT EXIST PI.EXE GOTO NOPI
IF NOT EXIST %X201PAT% GOTO XERROR
IF NOT EXIST %X201FIL% GOTO EERROR
IF NOT EXIST %X201ORG% REN %X201FIL% %X201ORG%
:PATORG
echo
echo %X201FIL% FOR %X201TYP% VERSION 201 ** PATCHING .............
echo
COPY %X201ORG% %X201FIL%
PI %X201FIL% %X201PAT% >NUL
IF ERRORLEVEL == 9 GOTO VERR
IF ERRORLEVEL == 0 GOTO SUCCESS
GOTO UNKNOWN
::
:NOPI
echo
echo CANNOT FIND PI.EXE
echo
echo The Novell Patch Install Utility (PI.EXE) is required to install
echo the patches for this product. Please copy PI.EXE to the directory
echo you are working in............................................
GOTO END
::
:XERROR
echo
echo CANNOT FIND %X201PAT%
GOTO END
::
:EERROR
IF EXIST %X201ORG% GOTO PATORG
echo
echo CANNOT FIND %X201FIL%
GOTO END
::
:VERR
CLS
ECHO ***** BYTE VERIFICATION FAILED *****
ECHO
ECHO YOU ARE NOT PATCHING THE ORIGINAL %X201FIL%
ECHO
ECHO PLEASE COPY THE ORIGINAL %X201FIL% TO THE CURRENT
ECHO DIRECTORY AND TRY AGAIN.
COPY %X201ORG% %1.BAT
DEL %X201ORG%
GOTO END
::
:SUCCESS
ECHO
ECHO PATCHES FOR %X201FIL% SUCCESSFULLY INSTALLED.......
ECHO
GOTO FIXED
::
:UNKNOWN
CLS
ECHO ***** UNKNOWN ERROR *****
ECHO
ECHO AN UNKNOWN ERROR HAS OCCURRED WHILE PATCHING %X201FIL%
ECHO
ECHO PLEASE CALL YOUR TECHNICAL SUPPORT REPRESENTATIVE FOR HELP.....
ECHO
GOTO END
::
:PARAM
echo
echo THE FORMAT IS:
echo
echo PATCHXQL [filename]
echo
echo WHERE [filename] IS: XQLP
echo XQLPO
echo XQLPOS2 { XQLP FOR OS2 }
echo
GOTO END
::
:FIXED
echo
echo %X201FIL% FOR %X201TYP% VERSION 201 ** PATCH COMPLETE **
echo
echo
echo ***** NOTICE: The %X201ORG% file in your current directory is the
echo original. This batch file renames %X201FIL% to %X201ORG%
echo if it does not find %X201ORG%. This will allow you to
echo keep the original on hand without patches applied.
echo The next time the patches are applied, it looks for
echo the %X201ORG% file first. Thus, patches will always be
echo applied to the unpatched version.
echo
echo IT IS YOUR RESPONSIBILITY TO PLACE THE UNPATCHED VERSION
echo IN THIS DIRECTORY THE FIRST TIME YOU USE THIS BATCH FILE.
echo
::
:END
SET X201ORG=
SET X201FIL=
SET X201PAT=
SET X201TYP=